<%@ page language="java" isErrorPage="true" %>
<%@ taglib uri="/WEB-INF/tlds/c.tld" prefix="c" %>
<%@ taglib uri="/WEB-INF/tlds/struts-bean.tld" prefix="bean" %>
<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1" />
<title>Console de param&eacute;trage des applications annuaires</title>
<c:set var="ctx" value="${pageContext.request.contextPath}" scope="request"/>
<link href="${ctx}/styles/page2.css" type="text/css" rel="stylesheet"/>
</head>
<body>
<script>
	var page = this;
	var pages = new Array();
	var i=0;
	var j;
	while(page = page.opener) {
		pages[i]=page;
		i++;
	}
	var l=pages.length;
	for(j=0;j<l-1;j++) {
		pages[j].close();
	}
	if(l > 1) {
		pages[pages.length-1].location = '${ctx}/jsp/error.jsp?exception=<%= exception %>';
		window.close();
	}
</script>
<div id="content">
<div id="subcontent">
	<p><bean:message key="errorPage.applicationError"/></p>
<% if (exception != null) { %>
    <p style="color: #000;font-weight:normal;"><%= exception %></p>
<% } else if(request.getParameter("exception") != null){ %>
    <p style="color: #000;font-weight:normal;"><%= request.getParameter("exception") %></p>
<% } else { %>
    <p style="color: #000;font-weight:normal;"><bean:message key="errorPage.applicationLogs"/></p>
<% } %>
<p><input type="button" value="<bean:message key="errorPage.homePage"/>" onclick="document.location='${ctx}/index.jsp';"/></p>
</div>
</div>
</body>
</html>